package cn.uai.activiti8.initializer;

import cn.uai.activiti8.cache.GlobalCache;
import org.springframework.boot.CommandLineRunner;
import org.springframework.context.annotation.Configuration;

import static cn.uai.activiti8.enums.RoleEnum.*;


/**
 * @desc 并行审批角色集合
 * @author uai
 * @since 2025/7/31 10:25
 * @version 1.0
 */
@Configuration
public class RoleCollectionInitializer implements CommandLineRunner {
    @Override
    public void run(String... args) {
        GlobalCache.PARALLEL_APPROVAL_ROLE.add(ROLE_STORE_MANAGER.getRid());
        GlobalCache.PARALLEL_APPROVAL_ROLE.add(ROLE_WAREHOUSE_KEEPER.getRid());
        GlobalCache.PARALLEL_APPROVAL_ROLE.add(ROLE_ASSISTANT_REGION_MANAGER.getRid());
    }
}
